Normative: prohibit using setFromBase64/setFromHex on immutable-backed Uint8Arrays#62
Normative: prohibit using setFromBase64/setFromHex on immutable-backed Uint8Arrays#62
Conversation
|
The rendered spec for this PR is available at https://tc39.es/proposal-immutable-arraybuffer/pr/62. |
ljharb
left a comment
There was a problem hiding this comment.
agree this is just a spec bug and the PR makes it match committee consensus
michaelficarra
left a comment
There was a problem hiding this comment.
I don't love accessMode being optional, but this is fine for now.
|
It's just matching ValidateTypedArray from this proposal; probably either both should be optional or neither. |
This is indeed a bit of a problem here. As soon as any spec user of that function forgets to set the correct mode the immutability is broken. This also means that as long as this proposal is not fully merged, other concurrent proposals will potentially continue to break immutability. |
Fixes #55 in the manner described therein.
Tests: tc39/test262#4998
I don't think this requires committee approval since it was obviously always the intention.